sqlplus gsms/any02gs@oraeu << EOF
update G_POL_PINKRIBBON
set count = (SELECT COUNT (id)
            FROM g_mb_member
            WHERE reg_country = 'pol' 
                and created between TO_DATE ('20081001', 'YYYYMMDD') 
                                and TO_DATE ('20081031', 'YYYYMMDD')   + 0.99999
            )
    , CREATED = SYSDATE;    
commit; 
EOF
